<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>添加界面</title>
    <meta name="renderer" content="webkit"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
    <link rel="stylesheet" href="/lib/layui-v2.5.5/css/layui.css" media="all"/>
    <link rel="stylesheet" href="/css/public.css" media="all"/>
    <style>
        body {
            background-color: #ffffff;
        }
    </style>
</head>
<body>
<div class="layui-form layuimini-form">
    <div>
        <div style="border:solid #00a2d4 1px;padding-right: 10px">
            <div class="layui-form-item" style="margin-top: 15px">
                <label class="layui-form-label required">名称:</label>
                <div class="layui-input-block">
                    <input type="text" name="name" lay-verify="required" lay-reqtext="名称不能为空" value=""
                           class="layui-input"></input>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">编码:</label>
                <div class="layui-input-block">
                    <input type="text" name="code" lay-verify="required" lay-reqtext="编码不能为空" value=""
                           class="layui-input"></input>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">院区:</label>
                <div class="layui-input-block">
                    <select name="porperty1" class="layui-select" lay-verify="required" lay-reqtext="所属院区不能为空">
                        <option value="H0001">主院区</option>
                        <option value="H0002">阿乐惠院区</option>
                        <option value="H0003">维吾尔医医院</option>
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">机构类型</label>
                <div class="layui-input-block">
                    <select name="organizationtypeCode" class="layui-select" lay-verify="required"
                            lay-reqtext="机构类型不能为空">
                        <option value="YL">医疗</option>
                        <option value="XZ">行政</option>
                        <option value="KY">科研</option>
                        <option value="HQ">后勤</option>
                        <option value="JX">教学</option>
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">细分类别:</label>
                <div class="layui-input-block">
                    <select name="porperty3" class="layui-select" lay-verify="required" lay-reqtext="所属院区不能为空">
                        <option value="0">其他</option>
                        <option value="1">临床专科</option>
                        <option value="21">诊疗组</option>
                        <option value="3">门诊</option>
                        <option value="4">医技</option>
                        <option value="51">药库</option>
                        <option value="52">药房</option>
                        <option value="6">手术</option>
                        <option value="7">护理单元</option>
                        <option value="8">门诊诊区</option>
                        <option value="9">预约小组</option>
                        <option value="10">教学单元</option>
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">拼音码:</label>
                <div class="layui-input-block">
                    <input type="text" name="pinyinCode" value="" class="layui-input"></input>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">五笔码:</label>
                <div class="layui-input-block">
                    <input type="text" name="wubiCode" value="" class="layui-input"></input>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label required">地址:</label>
                <div class="layui-input-block">
                    <input type="text" name="address" value="" class="layui-input"></input>
                </div>
            </div>
        </div>
        <div style="padding-top: 5px">
            <div class="layui-input-block">
                <button class="layui-btn layui-btn-normal layui-btn-sm" lay-submit lay-filter="saveBtn">确认</button>
                <button class="layui-btn layui-btn-primary layui-btn-sm">取消</button>
            </div>
        </div>
    </div>

</div>
<script src="/lib/layui-v2.5.5/layui.js" charset="utf-8"></script>
<script>
    layui.use(['form'], function () {
        var form = layui.form,
            layer = layui.layer,
            $ = layui.$;

        //监听提交
        form.on('submit(saveBtn)', function (data) {
            var index = layer.alert(JSON.stringify(data.field), {
                title: '最终的提交信息'
            }, function () {

                // 关闭弹出层
                layer.close(index);

                var iframeIndex = parent.layer.getFrameIndex(window.name);
                parent.layer.close(iframeIndex);

            });

            return false;
        });

    });
</script>
</body>
</html>
